<html>
	<head>
		<title>Endpoint Admin</title>
		<style type="text/css">
			.fileTable {
				border: 1px solid #000;
				border-collapse: collapse;
			}
			
			th { background-color: #ddd; }
			td, th {
				padding: 1px 5px 1px 5px;
				border: 1px solid #000;
			}
		</style>
	</head>
	<body>
	<h1>Admin</h1>

	<form method="post" action="[% admin_submit_url %]" enctype="multipart/form-data">
		<div id="settings">
			<h2>Settings</h2>
			<div>
				<p>
					Endpoint Owner OpenID: <input name="owner_openid" id="owner_openid" type="text" size="20" value="[% owner_openid %]" /><input name="submit" type="submit" value="Submit" />
				</p>
				
				<div id="privacy">
					<h3>Privacy</h3>
					<div>
						<p>
							Private Predicates:
							<textarea id="priv_preds" name="priv_preds" rows="20" cols="80">[% priv_preds %]</textarea>
						</p>
						
						<p>
							Authorized Users:
							<textarea id="auth_query" name="auth_query" rows="20" cols="80">[% auth_query %]</textarea>
						</p>
					</div>
				</div>
			</div>
		</div>
		
		<h2>Data</h2>
		<input name="admin" id="admin" type="hidden" value="1" />
		<p>
			Add RDF from URI: <input name="add_uri" id="add_uri" type="text" size="60" /><input name="submit" type="submit" value="Submit" />
		</p>
		
		<table class="fileTable">
			<tr>
				<th>Source</th>
				<th>Statements</th>
				<th>Delete</th>
				<th>Replace</th>
			</tr>
		[% FOREACH file = files %]
			<tr>
				<td>[% file.source %]</td>
				<td>[% file.count %]</td>
				<td>[% file.delete_field %]</td>
			</tr>
		[% END %]
			<tr><th colspan="4"><input name="submit" id="submit" type="submit" value="Submit" /></th></tr>
		</table>
	</form>
	</body>
</html>
